Skip to content

cli: add JSON output for concore validate#533

Merged
pradeeban merged 2 commits intoControlCore-Project:devfrom
Titas-Ghosh:feat/validate-json-output
Apr 3, 2026
Merged

cli: add JSON output for concore validate#533
pradeeban merged 2 commits intoControlCore-Project:devfrom
Titas-Ghosh:feat/validate-json-output

Conversation

@Titas-Ghosh
Copy link
Copy Markdown
Contributor

Adds optional JSON output to concore validate via:

concore validate workflow.graphml --format json

Right now concore validate is human readable but not machine readable. This makes downstream integration harder than it needs to be. Adding a structured JSON mode gives us a clean foundation for future editor/API/CI workflows without changing the current CLI experience.

Changes

  • add --format {text,json} to validate
  • emit structured JSON with:
    • valid
    • errors
    • warnings
    • info
    • summary
  • include error_type and node_id where applicable
  • add focused test coverage for valid and missing-source cases

I have made sure that the existing text output remains the default and there are no behavior change to current CLI usage

Also the line changes are a bit higher mainly because validate.py previously stored only plain strings, to support JSON cleanly, the validator now attaches structured metadata while preserving the same text mode behavior

@pradeeban pradeeban merged commit dccbcd4 into ControlCore-Project:dev Apr 3, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants